/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package br.jm.acionista.entity;

import java.io.Serializable;
import java.math.BigDecimal;
import javax.persistence.*;
import javax.validation.constraints.NotNull;

/**
 *
 * @author joao
 */
@Entity
@Table(name = "transferencia_cautela", catalog = "acionista", schema = "dbo")
@NamedQueries({
    @NamedQuery(name = "TransferenciaCautela.findAll", query = "SELECT t FROM TransferenciaCautela t")})
public class TransferenciaCautela implements Serializable {
    private static final long serialVersionUID = 1L;
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Basic(optional = false)
    @NotNull
    @Column(name = "id_transferencia", nullable = false)
    private Integer idTransferencia;
    @Column(name = "num_transferencia", precision = 18, scale = 0)
    private BigDecimal numTransferencia;

    public TransferenciaCautela() {
    }

    public TransferenciaCautela(Integer idTransferencia) {
        this.idTransferencia = idTransferencia;
    }

    public Integer getIdTransferencia() {
        return idTransferencia;
    }

    public void setIdTransferencia(Integer idTransferencia) {
        this.idTransferencia = idTransferencia;
    }

    public BigDecimal getNumTransferencia() {
        return numTransferencia;
    }

    public void setNumTransferencia(BigDecimal numTransferencia) {
        this.numTransferencia = numTransferencia;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (idTransferencia != null ? idTransferencia.hashCode() : 0);
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof TransferenciaCautela)) {
            return false;
        }
        TransferenciaCautela other = (TransferenciaCautela) object;
        if ((this.idTransferencia == null && other.idTransferencia != null) || (this.idTransferencia != null && !this.idTransferencia.equals(other.idTransferencia))) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "br.jm.acionista.entity.TransferenciaCautela[ idTransferencia=" + idTransferencia + " ]";
    }
    
}
